package com.cy.detectsys.mapper;

import com.cy.detectsys.entity.DbWiki;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import org.apache.ibatis.annotations.Select;
import org.apache.ibatis.annotations.Update;

/**
* @author admin
* @description 针对表【db_wiki】的数据库操作Mapper
* @createDate 2024-05-10 19:35:59
* @Entity com.cy.detectsys.entity.DbWiki
*/
public interface DbWikiMapper extends BaseMapper<DbWiki> {

    @Update("UPDATE db_wiki \n" +
            "SET content =  #{content}\n" +
            "WHERE\n" +
            "domain = #{domain}")
    void updateByDomian(DbWiki dbWiki);

    @Select("SELECT count(1) from db_wiki \n" +
            "WHERE\n" +
            "domain = #{domain}")
    Boolean selectDomian(String domain);
}




